package com.ruoyi.deeplearn.component;

import com.ruoyi.common.utils.StringUtils;
import org.checkerframework.checker.units.qual.A;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

@Component
public class ForecastRedisReceiver {
    @Autowired
    private ModelForecastComponent modelForecastComponent;
    public void receiveMessage(String message) {
        if(!StringUtils.isEmpty(message)){
            Long deepForecastId = Long.parseLong(message);
            modelForecastComponent.subscribe(deepForecastId);
        }
    }
}
